<%@ page contentType="text/html; charset=GBK" %><%@ page import="java.util.*" %><%@ page import="com.ionglobal.db.*" %><%@ page import="com.ionglobal.lib.*" %><%@ page import="com.ionglobal.misc.*" %><%@ page import="com.dhec.ggs.*"%><%
DBI dbi = new DBI();
Request Request = new Request(request);
try{
	String q = Request.getString("q");
	if(q.length()>0){
		dbi.execQuery("select * from sys_dict where iType in (select iId from sys_dicttype where scode='office') and (sname like '%"+q+"%' or SP0 like '%"+q+"%') order by iid");
		int count = 0;
		while(dbi.rsNext()){
			if(count==0)
				out.print("<ul>");
%>
				<li><%=dbi.rsGetString("SP0")+" "+dbi.rsGetString("sname")%><input type="hidden" id="data<%=count%>" value="<%=dbi.rsGetString("SP0")+" "+dbi.rsGetString("sname")%>" /></li>
<%
			count++;
		}
		dbi.rsClose();
		if(count>0)
			out.print("</ul>");
	}
}catch(Exception e){
	e.printStackTrace();
}finally{
	dbi.closeAll();	
}
%>